/*
 * BarService.java
 *
 * Created on 4 de noviembre de 2006, 13:40
 *
 */

package cheers.service;

import java.util.List;
import cheers.model.Bar;
import cheers.orm.dao.IBarDAO;

/**
 *
 * @author Santiago Hirschfeld
 */
public class BarService {
    
    private IBarDAO barDAO = null;
    
    //<editor-fold defaultstate="collapsed" desc=" Spring Dependency Injection Setters ">
    public void setBarDAO(IBarDAO barDAO) {
        this.barDAO = barDAO;
    }
    //</editor-fold>
    
    public BarService() {
    }
    
    public List<Bar> getAllBars() {
        return barDAO.getAllBars();
    }
    
    public int getNumberOfBars() {
        return getAllBars().size();
    }
}
